Optimal. Leaf size=129 \[ -\frac {\text {ArcTan}\left (\sqrt {1-\sqrt [4]{-1}} \cot (x)\right )}{4 \sqrt {1-\sqrt [4]{-1}}}-\frac {\text {ArcTan}\left (\sqrt {1+\sqrt [4]{-1}} \cot (x)\right )}{4 \sqrt {1+\sqrt [4]{-1}}}-\frac {\text {ArcTan}\left (\sqrt {1-(-1)^{3/4}} \cot (x)\right )}{4 \sqrt {1-(-1)^{3/4}}}-\frac {\text {ArcTan}\left (\sqrt {1+(-1)^{3/4}} \cot (x)\right )}{4 \sqrt {1+(-1)^{3/4}}} \]
[Out]
________________________________________________________________________________________
Rubi [A]
time = 0.12, antiderivative size = 129, normalized size of antiderivative = 1.00, number of steps
used = 9, number of rules used = 3, integrand size = 8, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.375, Rules used = {3290, 3260, 209}
\begin {gather*} -\frac {\text {ArcTan}\left (\sqrt {1-\sqrt [4]{-1}} \cot (x)\right )}{4 \sqrt {1-\sqrt [4]{-1}}}-\frac {\text {ArcTan}\left (\sqrt {1+\sqrt [4]{-1}} \cot (x)\right )}{4 \sqrt {1+\sqrt [4]{-1}}}-\frac {\text {ArcTan}\left (\sqrt {1-(-1)^{3/4}} \cot (x)\right )}{4 \sqrt {1-(-1)^{3/4}}}-\frac {\text {ArcTan}\left (\sqrt {1+(-1)^{3/4}} \cot (x)\right )}{4 \sqrt {1+(-1)^{3/4}}} \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
Rule 209
Rule 3260
Rule 3290
Rubi steps
\begin {align*} \int \frac {1}{1+\cos ^8(x)} \, dx &=\frac {1}{4} \int \frac {1}{1-\sqrt [4]{-1} \cos ^2(x)} \, dx+\frac {1}{4} \int \frac {1}{1+\sqrt [4]{-1} \cos ^2(x)} \, dx+\frac {1}{4} \int \frac {1}{1-(-1)^{3/4} \cos ^2(x)} \, dx+\frac {1}{4} \int \frac {1}{1+(-1)^{3/4} \cos ^2(x)} \, dx\\ &=-\left (\frac {1}{4} \text {Subst}\left (\int \frac {1}{1+\left (1-\sqrt [4]{-1}\right ) x^2} \, dx,x,\cot (x)\right )\right )-\frac {1}{4} \text {Subst}\left (\int \frac {1}{1+\left (1+\sqrt [4]{-1}\right ) x^2} \, dx,x,\cot (x)\right )-\frac {1}{4} \text {Subst}\left (\int \frac {1}{1+\left (1-(-1)^{3/4}\right ) x^2} \, dx,x,\cot (x)\right )-\frac {1}{4} \text {Subst}\left (\int \frac {1}{1+\left (1+(-1)^{3/4}\right ) x^2} \, dx,x,\cot (x)\right )\\ &=-\frac {\tan ^{-1}\left (\sqrt {1-\sqrt [4]{-1}} \cot (x)\right )}{4 \sqrt {1-\sqrt [4]{-1}}}-\frac {\tan ^{-1}\left (\sqrt {1+\sqrt [4]{-1}} \cot (x)\right )}{4 \sqrt {1+\sqrt [4]{-1}}}-\frac {\tan ^{-1}\left (\sqrt {1-(-1)^{3/4}} \cot (x)\right )}{4 \sqrt {1-(-1)^{3/4}}}-\frac {\tan ^{-1}\left (\sqrt {1+(-1)^{3/4}} \cot (x)\right )}{4 \sqrt {1+(-1)^{3/4}}}\\ \end {align*}
________________________________________________________________________________________
Mathematica [C] Result contains higher order function than in optimal. Order 9 vs. order 3 in
optimal.
time = 0.16, size = 141, normalized size = 1.09 \begin {gather*} 8 \text {RootSum}\left [1+8 \text {$\#$1}+28 \text {$\#$1}^2+56 \text {$\#$1}^3+326 \text {$\#$1}^4+56 \text {$\#$1}^5+28 \text {$\#$1}^6+8 \text {$\#$1}^7+\text {$\#$1}^8\&,\frac {2 \text {ArcTan}\left (\frac {\sin (2 x)}{\cos (2 x)-\text {$\#$1}}\right ) \text {$\#$1}^3-i \log \left (1-2 \cos (2 x) \text {$\#$1}+\text {$\#$1}^2\right ) \text {$\#$1}^3}{1+7 \text {$\#$1}+21 \text {$\#$1}^2+163 \text {$\#$1}^3+35 \text {$\#$1}^4+21 \text {$\#$1}^5+7 \text {$\#$1}^6+\text {$\#$1}^7}\&\right ] \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
________________________________________________________________________________________
Maple [C] Result contains higher order function than in optimal. Order 9 vs. order
3.
time = 0.35, size = 67, normalized size = 0.52
method | result | size |
default | \(\frac {\left (\munderset {\textit {\_R} =\RootOf \left (\textit {\_Z}^{8}+4 \textit {\_Z}^{6}+6 \textit {\_Z}^{4}+4 \textit {\_Z}^{2}+2\right )}{\sum }\frac {\left (\textit {\_R}^{6}+3 \textit {\_R}^{4}+3 \textit {\_R}^{2}+1\right ) \ln \left (\tan \left (x \right )-\textit {\_R} \right )}{\textit {\_R}^{7}+3 \textit {\_R}^{5}+3 \textit {\_R}^{3}+\textit {\_R}}\right )}{8}\) | \(67\) |
risch | \(\left (\munderset {\textit {\_R} =\RootOf \left (8192 \textit {\_Z}^{4}+\left (128-128 i\right ) \textit {\_Z}^{2}+1-i\right )}{\sum }\textit {\_R} \ln \left ({\mathrm e}^{2 i x}+\left (1024+1024 i\right ) \textit {\_R}^{3}+\left (-128+128 i\right ) \textit {\_R}^{2}+\left (16-16 i\right ) \textit {\_R} +1+2 i\right )\right )+\left (\munderset {\textit {\_R} =\RootOf \left (8192 \textit {\_Z}^{4}+\left (128+128 i\right ) \textit {\_Z}^{2}+1+i\right )}{\sum }\textit {\_R} \ln \left ({\mathrm e}^{2 i x}+\left (-1024+1024 i\right ) \textit {\_R}^{3}+\left (-128-128 i\right ) \textit {\_R}^{2}+\left (-16-16 i\right ) \textit {\_R} +1-2 i\right )\right )\) | \(104\) |
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Maxima [F]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \text {Failed to integrate} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Fricas [F(-1)] Timed out
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \text {Timed out} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Sympy [F(-1)] Timed out
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \text {Timed out} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Giac [F]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \text {could not integrate} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Mupad [B]
time = 3.11, size = 1025, normalized size = 7.95 \begin {gather*} -\mathrm {atan}\left (\frac {\mathrm {tan}\left (x\right )\,\sqrt {-\frac {\sqrt {2\,\sqrt {2}-3}}{128}-\frac {1}{128}}\,8{}\mathrm {i}}{\frac {\sqrt {2}\,\sqrt {2\,\sqrt {2}-3}}{2}+\frac {\sqrt {2}}{2}-\sqrt {2\,\sqrt {2}-3}-1}-\frac {\sqrt {2}\,\mathrm {tan}\left (x\right )\,\sqrt {-\frac {\sqrt {2\,\sqrt {2}-3}}{128}-\frac {1}{128}}\,4{}\mathrm {i}}{\frac {\sqrt {2}\,\sqrt {2\,\sqrt {2}-3}}{2}+\frac {\sqrt {2}}{2}-\sqrt {2\,\sqrt {2}-3}-1}+\frac {\mathrm {tan}\left (x\right )\,\sqrt {2\,\sqrt {2}-3}\,\sqrt {-\frac {\sqrt {2\,\sqrt {2}-3}}{128}-\frac {1}{128}}\,8{}\mathrm {i}}{\frac {\sqrt {2}\,\sqrt {2\,\sqrt {2}-3}}{2}+\frac {\sqrt {2}}{2}-\sqrt {2\,\sqrt {2}-3}-1}-\frac {\sqrt {2}\,\mathrm {tan}\left (x\right )\,\sqrt {2\,\sqrt {2}-3}\,\sqrt {-\frac {\sqrt {2\,\sqrt {2}-3}}{128}-\frac {1}{128}}\,4{}\mathrm {i}}{\frac {\sqrt {2}\,\sqrt {2\,\sqrt {2}-3}}{2}+\frac {\sqrt {2}}{2}-\sqrt {2\,\sqrt {2}-3}-1}\right )\,\sqrt {-\frac {\sqrt {2\,\sqrt {2}-3}}{128}-\frac {1}{128}}\,2{}\mathrm {i}+\mathrm {atan}\left (\frac {\mathrm {tan}\left (x\right )\,\sqrt {\frac {\sqrt {2\,\sqrt {2}-3}}{128}-\frac {1}{128}}\,8{}\mathrm {i}}{\frac {\sqrt {2}\,\sqrt {2\,\sqrt {2}-3}}{2}-\frac {\sqrt {2}}{2}-\sqrt {2\,\sqrt {2}-3}+1}-\frac {\sqrt {2}\,\mathrm {tan}\left (x\right )\,\sqrt {\frac {\sqrt {2\,\sqrt {2}-3}}{128}-\frac {1}{128}}\,4{}\mathrm {i}}{\frac {\sqrt {2}\,\sqrt {2\,\sqrt {2}-3}}{2}-\frac {\sqrt {2}}{2}-\sqrt {2\,\sqrt {2}-3}+1}-\frac {\mathrm {tan}\left (x\right )\,\sqrt {2\,\sqrt {2}-3}\,\sqrt {\frac {\sqrt {2\,\sqrt {2}-3}}{128}-\frac {1}{128}}\,8{}\mathrm {i}}{\frac {\sqrt {2}\,\sqrt {2\,\sqrt {2}-3}}{2}-\frac {\sqrt {2}}{2}-\sqrt {2\,\sqrt {2}-3}+1}+\frac {\sqrt {2}\,\mathrm {tan}\left (x\right )\,\sqrt {2\,\sqrt {2}-3}\,\sqrt {\frac {\sqrt {2\,\sqrt {2}-3}}{128}-\frac {1}{128}}\,4{}\mathrm {i}}{\frac {\sqrt {2}\,\sqrt {2\,\sqrt {2}-3}}{2}-\frac {\sqrt {2}}{2}-\sqrt {2\,\sqrt {2}-3}+1}\right )\,\sqrt {\frac {\sqrt {2\,\sqrt {2}-3}}{128}-\frac {1}{128}}\,2{}\mathrm {i}+\mathrm {atan}\left (\frac {\mathrm {tan}\left (x\right )\,\sqrt {-\frac {\sqrt {-2\,\sqrt {2}-3}}{128}-\frac {1}{128}}\,8{}\mathrm {i}}{\frac {\sqrt {2}\,\sqrt {-2\,\sqrt {2}-3}}{2}+\frac {\sqrt {2}}{2}+\sqrt {-2\,\sqrt {2}-3}+1}+\frac {\sqrt {2}\,\mathrm {tan}\left (x\right )\,\sqrt {-\frac {\sqrt {-2\,\sqrt {2}-3}}{128}-\frac {1}{128}}\,4{}\mathrm {i}}{\frac {\sqrt {2}\,\sqrt {-2\,\sqrt {2}-3}}{2}+\frac {\sqrt {2}}{2}+\sqrt {-2\,\sqrt {2}-3}+1}+\frac {\mathrm {tan}\left (x\right )\,\sqrt {-2\,\sqrt {2}-3}\,\sqrt {-\frac {\sqrt {-2\,\sqrt {2}-3}}{128}-\frac {1}{128}}\,8{}\mathrm {i}}{\frac {\sqrt {2}\,\sqrt {-2\,\sqrt {2}-3}}{2}+\frac {\sqrt {2}}{2}+\sqrt {-2\,\sqrt {2}-3}+1}+\frac {\sqrt {2}\,\mathrm {tan}\left (x\right )\,\sqrt {-2\,\sqrt {2}-3}\,\sqrt {-\frac {\sqrt {-2\,\sqrt {2}-3}}{128}-\frac {1}{128}}\,4{}\mathrm {i}}{\frac {\sqrt {2}\,\sqrt {-2\,\sqrt {2}-3}}{2}+\frac {\sqrt {2}}{2}+\sqrt {-2\,\sqrt {2}-3}+1}\right )\,\sqrt {-\frac {\sqrt {-2\,\sqrt {2}-3}}{128}-\frac {1}{128}}\,2{}\mathrm {i}-\mathrm {atan}\left (\frac {\mathrm {tan}\left (x\right )\,\sqrt {\frac {\sqrt {-2\,\sqrt {2}-3}}{128}-\frac {1}{128}}\,8{}\mathrm {i}}{\frac {\sqrt {2}\,\sqrt {-2\,\sqrt {2}-3}}{2}-\frac {\sqrt {2}}{2}+\sqrt {-2\,\sqrt {2}-3}-1}+\frac {\sqrt {2}\,\mathrm {tan}\left (x\right )\,\sqrt {\frac {\sqrt {-2\,\sqrt {2}-3}}{128}-\frac {1}{128}}\,4{}\mathrm {i}}{\frac {\sqrt {2}\,\sqrt {-2\,\sqrt {2}-3}}{2}-\frac {\sqrt {2}}{2}+\sqrt {-2\,\sqrt {2}-3}-1}-\frac {\mathrm {tan}\left (x\right )\,\sqrt {-2\,\sqrt {2}-3}\,\sqrt {\frac {\sqrt {-2\,\sqrt {2}-3}}{128}-\frac {1}{128}}\,8{}\mathrm {i}}{\frac {\sqrt {2}\,\sqrt {-2\,\sqrt {2}-3}}{2}-\frac {\sqrt {2}}{2}+\sqrt {-2\,\sqrt {2}-3}-1}-\frac {\sqrt {2}\,\mathrm {tan}\left (x\right )\,\sqrt {-2\,\sqrt {2}-3}\,\sqrt {\frac {\sqrt {-2\,\sqrt {2}-3}}{128}-\frac {1}{128}}\,4{}\mathrm {i}}{\frac {\sqrt {2}\,\sqrt {-2\,\sqrt {2}-3}}{2}-\frac {\sqrt {2}}{2}+\sqrt {-2\,\sqrt {2}-3}-1}\right )\,\sqrt {\frac {\sqrt {-2\,\sqrt {2}-3}}{128}-\frac {1}{128}}\,2{}\mathrm {i} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________